#@layout() #define main()
<center>
	<h1>
		<font size="3">添加商品</font>
	</h1>
	<div class="table_box">
		<table class="list" width="800" border="1" bordercolor="#FF9966">
			<tbody>
				<tr>
					<th width="8%">商品ID</th>
					<th width="18%">名称</th>
					<th width="12%">条形码</th>
					<th width="8%">类型</th>
					<th width="8%">价格</th>
					<th width="5%">数量</th>
					<th width="10%">操作</th>
				</tr>

				#for(x : clothesPage.getList())
				<tr>
					<td style="text-align: center;">#(x.product_id)</td>
					<td style="text-align: center;">#(x.name)</td>
					<td style="text-align: center;">#(x.barcode)</td>
					<td style="text-align: center;">#(x.type)</td>
					<td style="text-align: center;">#(x.price)</td>
					<td style="text-align: center;"><input id="count" style="width:15px" type="number" name="count" min="1" max="10" value="1"/></td>
					<td><a href="/ClothingStorePOS/sell/addGoods?productId=#(x.product_id)&price=#(x.price)" onclick=a(this)>添加商品</a></td>
				</tr>
				#end
			</tbody>
		</table>
		<br>
	</div>
	#end
</center>

<script>
function a( obj)
{
 obj.href=obj.href+"&count="+document.getElementById("count").value;
}
</script>